package smedi.ismedi.web.bff.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.io.Serializable;

/**
 * @Author: xulinjun
 * @Date: 2021-6-8 11:13
 */
@Data
public class ExternalPersonEditRequest implements Serializable {
    @ApiModelProperty(value = "人员id")
    @NotNull(message = "人员id不为空！")
    private Long personId;

    @ApiModelProperty(value = "姓名", required = true)
    @Size(max = 50, message = "最大50个字符！")
    private String lastName;

    @ApiModelProperty(value = "性别", required = true)
    private String gender;

    @ApiModelProperty(value = "人员类型", required = true)
    private String personType;

    @ApiModelProperty(value = "工号", required = true)
    @Size(max = 50, message = "最大50个字符！")
    private String employeeNum;

    @ApiModelProperty(value = "手机号", required = true)
    @Size(min = 11, max = 11, message = "手机号码长度不正确！")
    @Pattern(regexp = "^((1)\\d{10})$", message = "手机号格式错误！")
    private String mobile;

    @ApiModelProperty(value = "邮箱地址", required = true)
    @Email(message = "邮箱地址格式错误！")
    private String email;

    @ApiModelProperty(value = "身份证", required = true)
    private String idCard;

    @ApiModelProperty(value = "修改身份证")
    private boolean modifyIdCard;

    @ApiModelProperty(value = "办公电话")
    @Size(max = 50, message = "最大50个字符！")
    private String officeTelephone;

    @ApiModelProperty(value = "头像uuid")
    private String imageUUID;

    @ApiModelProperty(value = "签章uuid")
    private String signatureUUID;

    @ApiModelProperty(value = "项目组织id", required = true)
    private Long projectOrganizationId;

    @ApiModelProperty(value = "项目职务", required = true)
    @Size(max = 50, message = "最大50个字符！")
    private String projectJob;

    @ApiModelProperty(value = "项目id", required = true)
    private Long projectId;

    @ApiModelProperty(value = "项目分配id")
    @NotNull(message = "项目分配id不为空！")
    private Long projectAssignmentId;
}
